package com.example.doer.reading.AppDataModel;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 * Created by 严旭江 on 2017/7/13.
 */

public class TopicReply implements Serializable{
    private String topicID;//回复所对应话题的ID--->也可自增
    private String replyID;//reply的ID--->自增
    private String userID;//该回复所对应的用户ID
    //private int replyToReplyID;//评论之间相互评论的ID  如果是-1 则说名是回复话题 如果>=0则说明是回复评论
    private String userName;//回复的用户名
    private int resID;//用户头像的ID
    private String replyContent;//回复的内容
    private int favoCount;//赞同数
    private int replyCount;//回复数目
    private int collectCount;//收藏数目
    private int replyAnswerCount;//回复的评论数目
    private Date date;//回复的日期
    private List<ReplyAnswer> replyAnswerList = new ArrayList<ReplyAnswer>();
    private boolean isThumbUp;
    private boolean isCollect;

    /**
     *
     * @param theTopicReplyID  问题回复的ID
     * @param theTopicReplyFromTopicID 该回答对应的问题ID
     * @param theReplyUserID  该回答的用户ID
     * @param theReplyContent 回答的内容
     * @param theFavoCount 回答的点赞数
     * @param theCollectCount 回答的收藏数目
     * @param theReplyAnswerCount 回答Reply数目
     * @param  IsThumbUp 是否点赞过
     * @param  IsCollect 是否收藏过
     */
    public TopicReply(String theTopicReplyID,
                      String theTopicReplyFromTopicID,
                      String theReplyUserID,
                      String theUserName,
                      String theReplyContent,
                      int theFavoCount,
                      int theCollectCount,
                      int theReplyAnswerCount,
                      boolean IsThumbUp,
                      boolean IsCollect){
        this.replyID = theTopicReplyID;
        this.topicID = theTopicReplyFromTopicID;
        this.userID = theReplyUserID;
        this.userName = theUserName;
        this.replyContent = theReplyContent;
        this.favoCount = theFavoCount;
        this.collectCount = theCollectCount;
        this.replyAnswerCount = theReplyAnswerCount;
        this.isThumbUp = IsThumbUp;
        this.isCollect = IsCollect;
    }
    public TopicReply(
            String theTopicID,
            String theReplyUserName,String theReplyContent,
            Date theDate){
        userName = theReplyUserName;
        topicID = theTopicID;
        //replyID = i++;
        replyContent = theReplyContent;
        favoCount = 0;replyCount = 0;
        date = theDate;
    }

    public boolean isThumbUp() {
        return isThumbUp;
    }
    public void setThumbUp(boolean thumbUp) {
        isThumbUp = thumbUp;
    }
    public boolean isCollect() {
        return isCollect;
    }
    public void setCollect(boolean collect) {
        isCollect = collect;
    }
    public int getCollectCount() {
        return collectCount;
    }
    public void setCollectCount(int collectCount) {
        this.collectCount = collectCount;
    }
    public int getReplyAnswerCount() {
        return replyAnswerCount;
    }
    public void setReplyAnswerCount(int replyAnswerCount) {this.replyAnswerCount = replyAnswerCount;}
    public Date getDate() {
        return date;
    }
    public void setDate(Date date) {
        this.date = date;
    }
    public List<ReplyAnswer> getReplyAnswerList() {
        return replyAnswerList;
    }
    public void setReplyAnswerList(List<ReplyAnswer> replyAnswerList) {
        this.replyAnswerList = replyAnswerList;
    }
    public String getReplyID() {
        return replyID;
    }
    public void setReplyID(String replyID) {
        this.replyID = replyID;
    }
    public String getTopicID() {
        return topicID;
    }
    public void setTopicID(String theTopicID) {
        topicID = theTopicID;
    }
    public String getUserID() {
        return userID;
    }
    public void setUserID(String userID) {
        this.userID = userID;
    }
    public String getUserName() {
        return userName;
    }
    public void setUserName(String userName) {
        this.userName = userName;
    }
    public int getResID() {
        return resID;
    }
    public void setResID(int resID) {
        this.resID = resID;
    }
    public String getReplyContent() {
        return replyContent;
    }
    public void setReplyContent(String replyContent) {
        this.replyContent = replyContent;
    }
    public int getFavoCount() {
        return favoCount;
    }
    public void setFavoCount(int favoCount) {
        this.favoCount = favoCount;
    }
    public int getReplyCount() {
        return replyCount;
    }
    public void setReplyCount(int replyCount) {
        this.replyCount = replyCount;
    }
}
